═══ 1. Introduction ═══ Stupid OS/2 Tricks (Double click on a bitmap) compiled by M. Woo for the Champaign-Urbana OS/2 Users Group release #3, Jan 1994 Information about this document: ■ Types of "tricks" included ■ How to submit tips and tricks ■ Revisions ■ Revision schedule ■ How this document was created ■ Disclaimer Copyright 1993-94 M. Woo. All Rights Reserved. ═══ 1.1. Types of "tricks" included ═══ This file contains various tips and tricks for OS/2 which have been gathered over time from various sources. Creation of this text was inspired by the "Clever Tricks" section of Tim Sipples' excellent Frequently Asked Questions list, a must read for all OS/2 owners. The type of tips and tricks included in this text are those which cover features of OS/2 that people often ask about, short REXX scripts which do interesting things, as well as other items which hopefully don't overlap information already contained in Tim Sipples' FAQ (well, not by TOO much, anyway). The tricks contained in this text do not make references to any specific product names, other than those components included in OS/2 itself. However, it may occasionally have been necessary to mention generic classes of utilities which are not included as part of OS/2. "Stupid OS/2 Tricks" can be freely distributed for non-commercial use, as long as it remains unaltered. This work is not public domain. A Japanese language version of Stupid OS/2 Tricks should now be available. Contact A. Kikuchi at kiku@ymtl01.yamato.ibm.co.jp for details. Related subject(s): ■ How to submit tips and tricks ═══ 1.2. How to submit tips and tricks ═══ If you know of any neat OS/2 tips or tricks that you're dying to share, please send them along. They would be greatly appreciated! If your tip or trick is used, your name will be listed along with it for all to see! Neat OS/2 tricks can be sent to: Internet, m-woo@uiuc.edu Fidonet, Sysop @ 1:233/4.0 Please also send any corrections to either of the addresses above. (these addresses are subject to change sometime soon) ═══ 1.3. Revisions ═══ INF revision marks Revisions/additions to this INF file will be displayed in the following text color (this is a revision). Related subject(s): ■ Revision schedule ═══ 1.4. Revision schedule ═══ This text will be updated when the number of new tips and tricks gathered warrants a new version. Revision History: ■ Release #1 - Nov 1993; initial release ■ Release #2 - Dec 1993 ■ Release #3 - Jan 1994 Related subject(s): ■ Revision marking ═══ 1.4.1. Release #2 ═══ Release #2 - Dec 1993 Changed: Using Elvis v1.8c beta instead of v1.6 Corrected info in "Getting more out of your command line" Corrected typos in SETMOUSE.CMD (this is important!!!) Added note to "Adding an 'open folder' entry to the desktop's popup menu" Improved BITMAP.CMD Added: Getting Epson ActionLaser 1500 to work Using keyboard shortcuts in PM Navigating in notebooks without a mouse Shutting down from a REXX script automatically Curing "jumpy mouse" Retrieving a "changed" icon Pasting between Windows applications Associating data files with programs Getting memory back from unused caches Changing the default view of a folder Dealing with OS/2 !! SYS messages on boot Using multiple arguments at the OS/2 command line Using EPM as a customized command shell Setting the startup directory for command line objects Restoring last desktop backup Creating new printer objects Viewing *.inf files more conveniently Formatting a diskette with the detach command Creating your own templates Using less memory for DOS images Replacing your Shredder if deleted ═══ 1.4.2. Release #3 ═══ Release #3 - Jan 1994 Changed: Added comment to "Prevent restarting automatically" Added note to "Speeding up some IDE drives" Corrected code and added comment to SETFONT.CMD. Replaced SETMOUSE.CMD with an improved version, SETPTR.CMD Added: Starting seamless Windows from the command line Resizing a command line window permanently Making the system "sleep" Substituting REPLACE for the COPY command Deleting "undeletable" objects Speeding up opening folders Managing your icons Enlarging the mouse cursor Manipulating objects through the Window List Booting OS/2 in full-screen mode Completing shutdown "Touching" a file's date and time Adjusting your swap file Adding command sessions to the desktop's popup menu Using SVGA.EXE under real DOS Selecting listbox entries without a mouse Making "no-shows" re-appear Opening multiple command line sessions from the desktop menu Creating a command line calculator Loading a DOS device driver into high memory Starting a DOS session with maximum free memory Finding the built-in icons Fixing "locked" INI files Using START to avoid the dreaded "clock" Coloring OS/2 command line sessions ═══ 1.5. How this document was created ═══ This document was written using the OS/2 port of Elvis v1.8c beta. Screen captures were done using PMCamera/2 v2.10, an IBM EWS package, then processed using JoeView v1.21. The resulting tagged document was compiled using the IPF compiler from the IBM OS/2 Developer's Toolkit v2.0. ═══ 1.6. Disclaimer ═══ I don't claim to be an expert on OS/2, so I can't guarantee that all the tips and tricks presented in this document will work with all configurations of OS/2. Thus, the following disclaimer: The reader/user assumes all responsibility, liability and risk for any damages, incidental or consequential, resulting from the use of the information provided in this document. No warranty is expressed or implied, and this document is only guaranteed to use space on your disk. ═══ 2. System ═══ This section covers tips and tricks which affect the system in general. Topics in this section: ■ Keeping applications from restarting at boot ■ Shutting down without a mouse ■ Rebooting from the command line ■ Finding settings for original objects ■ Controlling order of execution in Startup folder ■ Backing up the *.ini files ■ Removing device drivers for better performance ■ Speeding up some IDE drives ■ Disabling use of the floppy drives ■ Getting Epson ActionLaser 1500 to work ■ Getting memory back from unused caches ■ Dealing with OS/2 !! SYS messages on boot ■ Restoring last desktop backup ■ Viewing *.inf files more conveniently ■ Using less memory for DOS images ■ Booting OS/2 in full-screen mode ■ Completing shutdown ■ Adjusting your swap file ■ Using SVGA.EXE under real DOS ■ Loading a DOS device driver into high memory ■ Fixing "locked" INI files ═══ 2.1. Keeping applications from restarting at boot ═══ When OS/2 is started, it automatically opens applications which were open during the last OS/2 session. To keep applications from restarting on boot, you can use either the manual or automatic method. Related subject(s): ■ Prevent restarting manually ■ Prevent restarting automatically ■ Rebooting from the command line ═══ 2.1.1. Prevent restarting manually ═══ To prevent applications from restarting during boot, hold down the Ctrl, left Shift, and F1 keys at the same time, beginning when the mouse pointer appears until the icons begin appearing on the desktop. If you find that disk activity stops, you may have to release the keys and then quickly hold them down again. Related subject(s): ■ Prevent restarting automatically ═══ 2.1.2. Prevent restarting automatically ═══ Placing the line SET RESTARTOBJECTS=STARTUPFOLDERSONLY,REBOOTONLY into your CONFIG.SYS file will prevent any applications which had been open in the last session from opening, but will allow programs in the Startup folder to open. (this line may be order-dependent on some systems) Related subject(s): ■ Prevent restarting manually ═══ 2.2. Shutting down without a mouse ═══ To shut OS/2 down without a mouse, press Ctrl-Esc to bring up the Window List, choose the Desktop, press the Spacebar to deselect any icons, press Shift-F10 to pop up the Desktop's menu, choose Shutdown. ═══ 2.3. Rebooting from the command line ═══ To reboot OS/2 down from the command line, type SETBOOT /B or SETBOOT /IBD: where is the letter of the drive or partition to which you wish to boot Related subject(s): ■ Keeping applications from restarting at boot ■ SHUTDOWN.CMD ═══ 2.4. Finding settings for original objects ═══ The settings for all of the objects which were created upon installation of your OS/2 system are contained in the INI.RC file, located in the \OS2 subdirectory. Those handy with REXX and the external REXXutils can use the information contained in the INI.RC file to rebuild the original OS/2 objects. Related subject(s): ■ Replacing your Shredder if deleted ═══ 2.5. Controlling order of execution in Startup folder ═══ ═══ Startup execution window 1 ═══ You can control the order in which objects in your Startup folder execute. 1. Open the Startup folder in either Flowed or Non-flowed view. 2. Drag objects or their shadows into the Startup Folder in the order you want them to execute. ═══ Startup folder ═══ Startup folder in Flowed view with item being dragged into it. ═══ 2.6. Backing up the *.ini files ═══ Much of your system's customization is stored in two files, OS2.INI and OS2SYS.INI. To back up these important files, add the following line to the beginning of your CONFIG.SYS: CALL=:\OS2\XCOPY.EXE :\OS2\OS*.INI :\ where is the letter of the drive in which XCOPY.EXE is found is the letter of the drive in which the *.ini files are found is the letter of the drive in which you would like to locate the backups of the *.ini files is the path in which you would like to locate the backups of the *.ini files Related subject(s): ■ Restoring last desktop backup ═══ 2.7. Removing device drivers for better performance ═══ contributed by Jack Tan If you aren't using the DOS subsystem, you can improve performance by removing DOS-specific device drivers from loading in your CONFIG.SYS (they generally begin with the letter V). The same applies to Win-OS/2, HPFS, CD-ROM drivers as well. Related subject(s): ■ Getting memory back from unused caches ═══ 2.8. Speeding up some IDE drives ═══ contributed by Jack Tan Try adding switches to the BASEDEV=IBM1S506.ADD line: BASEDEV=IBM1S506.ADD /A:0 /U:0 /SMS and use /V to see if the /SMS works (/V = verbose). This is supposed to speed up IDE drives that support this feature; otherwise, it will be ignored. (note: the switches above affect the first drive on the first adapter in the system -- for more information on the switches, search for "basedev" in your online OS/2 Command Reference) ═══ 2.9. Disabling use of the floppy drives ═══ by Darius Vaskelis To prevent users from using the floppy drives under OS/2, such as in a workstation situation: Remove the following line from your CONFIG.SYS: BASEDEV=IBMxFLPY.ADD Where x is 1 for ISA and EISA, or 2 for Microchannel. ═══ 2.10. Getting Epson ActionLaser 1500 to work ═══ To get an Epson ActionLaser to work with OS/2 2.1: 1. First, follow the standard steps for non-working printers under OS/2: a) Make sure you have a compliant cable. A parallel cable should have all 25 pins wired, unfortunately, a lot of cables currently manufactured only have 18 pins wired. b) Check your interrupts. ISA and EISA bus machines cannot share interrupts under OS/2. Often, a sound card will be set to the same interrupt as LPT1 (IRQ7), and must be changed. c) Get a compatible I/O card. Some parallel port cards don't seem to work correctly under OS/2. 2. Finally, for the Epson ActionLaser, change the "Busy Delay" to +5 (covered in p.4-15 of the Epson's manual). ═══ 2.11. Getting memory back from unused caches ═══ from the OS/2 2.1 Technical Reference You can increase available resources by disabling unused caches. If you are running an HPFS-only system, remove (or REM) the DISKCACHE line in your CONFIG.SYS file. Similarly, if you are running a FAT-only system, remove (or REM) the IFS=:\OS2\HPFS.IFS line in your CONFIG.SYS. Related subject(s): ■ Removing device drivers for better performance ═══ 2.12. Dealing with OS/2 !! SYS messages on boot ═══ contributed by Jack Tan The error message: OS/2 !! SYS01475 OS/2 !! SYS02027 means that the system files can't be found. Try removing any diskettes from the disk drives. If this message appears when trying to boot from a hard disk, use SYSINSTX to restore the OS/2 system files. ═══ 2.13. Restoring last desktop backup ═══ contributed by Jack Tan To make the Alt-F1 trick restore your last desktop backup instead of the (ugly) default, replace the CONFIG.SYS, OS2.INI, and OS2SYS.INI in \OS2\INSTALL with the files from your last backup. Make sure to save the original files in \OS2\INSTALL before replacing them. Related subject(s): ■ Backing up the *.ini files ═══ 2.14. Viewing *.inf files more conveniently ═══ contributed by Jack Tan Here are two tips to make viewing OS/2 *.inf files more convenient: 1. Put several INF files together using a plus sign. On the command line (or 'Parameters' field of the settings notebook), enter something such as: e.g., :\BOOKS\FILE1.INF+:\BOOKS\FILE2.INF+ :\BOOKS\FILE3.INF. The pathnames aren't necessary if the file is in a directory specified by the HELP environmental variable. 2. You can assign the book names to an environmental variable: e.g., SET FILE=:\BOOKS\FILE1.INF+:\BOOKS\FILE2.INF+ :\BOOKS\FILE3.INF and execute VIEW.EXE using the variable name (e.g., VIEW FILE). ═══ 2.15. Using less memory for DOS images ═══ When you load a DOS image file (Virtual Machine Boot, or VMB), the entire diskette image is loaded into memory. Since the files on the DOS image diskette don't take up much room themselves, much of the memory used for the diskette is wasted. Therefore, in order to regain memory when loading the specific DOS session, try using double-density diskettes to make your DOS images, instead of high-density diskettes. ═══ 2.16. Booting OS/2 in full-screen mode ═══ You can boot OS/2 in full-screen mode, and still retain Presentation Manager support for multiple sessions: 1. Change: SET RUNWORKPLACE=:\OS2\PMSHELL.EXE in your CONFIG.SYS file to: SET RUNWORKPLACE=:\OS2\CMD.EXE /FS where is the drive on which OS/2 resides. 2. Create the file STARTUP.CMD in your OS/2 boot drive's root directory. STARTUP.CMD should contain the following lines: @ECHO OFF START /FS EXIT Related subject(s): ■ Using OS/2 without the Workplace Shell ═══ 2.17. Completing shutdown ═══ If shutdown seems to "hang" at the first shutdown message box, this trick sometimes works: 1. Press the Ctrl-Esc keys. 2. Wait for about a minute. 3. In many cases, a dialog box will pop up telling you that the Workplace Shell isn't responding to system requests, and will give you the choice of clicking on Enter to end the application, or Cancel. 4. Click on the Enter box. The shutdown usually proceeds normally. ═══ 2.18. Adjusting your swap file ═══ If you have disk space to spare, you can adjust the default startup size of your swap file (SWAPPER.DAT) to improve system performance. The default startup size of SWAPPER.DAT is set in your CONFIG.SYS file with the line: SWAPPATH=: where is the default startup size of SWAPPER.DAT. To adjust the startup size for better performance: 1. Monitor the size of the SWAPPER.DAT over the course of a normal day's work. A third-party utility for monitoring swap file size makes this task a bit easier. 2. Note the maximum size that SWAPPER.DAT reaches during normal usage. 3. Change the parameter of SWAPPATH to reflect at least the maximum swap file size you noted ( is measured in kilobytes). CAUTION: You MUST have enough free drive space to use this tip. If the size of the parameter violates the amount needed for the parameter, your system will not boot. ═══ 2.19. Using SVGA.EXE under real DOS ═══ contributed by Jack Tan Running SVGA.EXE in a VDM usually results in a file called SVGADATA.PMI, which contains information which lets OS/2 access SVGA graphics modes. Sometimes, SVGA.EXE has trouble "seeing" the video chip, and extended graphics modes won't work correctly. If so, try running SVGA.EXE under real DOS or a VMB. This will create a file named SVGADATA.DOS. Rename SVGADATA.DOS to SVGADATA.PMI and copy it into your \OS2 subdirectory. ═══ 2.20. Loading a DOS device driver into high memory ═══ ═══ Load into high memory ═══ contributed by Xavier Caballe In order to load a DOS device driver into high memory in a particular DOS Session: 1. Open the settings notebook for the DOS object. 2. Choose the Session tab. 3. Click on the DOS Settings button. 4. Highlight the DOS_DEVICE setting 5. Add 'SIZE=0' (without quotes) before the path and filename for the device driver to load in high memory. For example: SIZE=0 C:\OS2\MDOS\ANSI.SYS In this example, the ANSI.SYS will be loaded in the high memory area (if available). ═══ Loading device drivers high ═══ DOS Settings for loading a device driver high. ═══ 2.21. Fixing "locked" INI files ═══ contributed by Jack Tan If your INI files (OS2.INI and OS2SYS.INI) stop saving system changes, they may have been marked read-only. To reset the read-only attribute: 1. Change to your \OS2 subdirectory. 2. Type attrib -r os2*.ini at an OS/2 command prompt. 3. You may have to shutdown and reboot. Note: if using OS/2 2.0, you may have to boot OS/2 from your installation floppies in order to reset the attributes. ═══ 3. Desktop ═══ This section covers tips and tricks which relate to the Workplace Shell. Topics in this section: ■ Saving desktop without shutting down ■ Adding an "open folder" entry to the desktop's popup menu ■ Changing color of shadow icon text ■ Moving icon a small distance ■ Changing desktop bitmaps randomly at specified interval ■ Changing the standard mouse pointer ■ Making an object prompt for a parameter ■ Finding a "covered" icon ■ Changing icon text color ■ Recovering after an accidental Arrange ■ Creating an onscreen "app bar" ■ Creating a "trash can" ■ Selecting objects without mouse ■ Hiding a folder ■ Creating a system file editor object ■ Retrieving a "changed" icon ■ Associating data files with programs ■ Creating new printer objects ■ Creating your own templates ■ Replacing your Shredder if deleted ■ Deleting "undeletable" objects ■ Managing your icons ■ Finding the built-in icons ═══ 3.1. Saving desktop without shutting down ═══ To save the settings of your desktop without shutting down OS/2: by Jack Tan 1. Open the Settings folder for the Desktop. 2. Choose the Window tab. 3. Under Object Open Behavior, choose Create New Object. 4. Close the Settings folder. 5. Click on the arrow next to Open in the Desktop's popup menu; choose Icon View. 6. A folder of your Desktop should appear. You can arrange this folder any way you wish. 7. Close the folder of your Desktop to save its settings. The icon positions will be saved. 8. Change the Object Open Behavior to Display Existing Window. 9. To activate the newly-saved Desktop, use a kill utility to kill the second PMSHELL process. The Workplace Shell will restart with your newly-saved icon settings. Related subject(s): ■ Recovering after an accidental Arrange ═══ 3.2. Adding an "open folder" entry to the desktop's popup menu ═══ To add an entry to the desktop's popup menu which allows you to open a specific folder: 1. Create a REXX script, OPEN.CMD to open the folder. 2. Open the Templates folder. 3. Use the right mouse button to drag a copy of the Program template to the desired final location. Its Settings notebook should open. 4. Fill in the path and file name (OPEN.CMD) on the Programs page. Complete the General page as desired. 5. Close the Settings notebook. 6. Open the Settings notebook for the Desktop. 7. Choose the Menu tab. 8. If using OS/2 v2.1, drag the icon of your newly-created OPEN.CMD object onto the box underneath "Actions on menu: Primary pop-up menu." If using OS/2 v2.0, click on the Create Another button and fill in the proper information. 9. The menu choice for your OPEN.CMD object should now be available on the desktop's popup menu. Note: If you repeat the "call SysSetObjectData" line a second time, the folder will open in the foreground. Related subject(s): ■ Adding command sessions to the desktop's popup menu ■ Opening multiple command line sessions from the desktop menu ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 3.3. Changing color of shadow icon text ═══ ═══ Shadow icon text window 1 ═══ To change the color of the shadow icon text: 1. Open the Scheme Palette. 2. Choose Shadow Text. 3. Choose the desired color from the color wheel. 4. Close the Scheme Palette. 5. Drag (or Alt-drag) the desired scheme to the desired folder with the right mouse button. Related subject(s): ■ Changing icon text color ═══ Scheme Palette ═══ Scheme Palette with Shadow Text highlighted. ═══ 3.4. Moving icon a small distance ═══ ═══ Moving icon window 1 ═══ from Tim Sipples' FAQ To move an icon a small distance, "grab" the outer edge of the icon with the mouse and drag it to the new position. ═══ Moving icon ═══ Moving an icon a small distance. ═══ 3.5. Changing desktop bitmaps randomly at specified interval ═══ The Desktop bitmaps can be changed via a REXX script, BITMAP.CMD. Note that this script does not support tiling of bitmaps. Changes to bitmap.cmd (thanks to Jack Tan) added so that bitmap subdirectory is no longer hard-coded into the script. Other REXX scripts: ■ OPEN.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 3.6. Changing the standard mouse pointer ═══ contributed by Jack Tan; original by Dann Lunsford You can replace the various mouse pointers with your own customized creations, and can remove the customized pointers. 1. Use the Icon Editor to create a mouse pointer file with the extension *.PTR. 2. Create the REXX script, SETPTR.CMD. 3. Type SETPTR.CMD /? for help. Other REXX scripts: ■ OPEN.CMD ■ BITMAP.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 3.7. Making an object prompt for a parameter ═══ ═══ Object prompt window 1 ═══ To make an object prompt for a parameter when invoked 1. Open the Settings notebook for the object. 2. In the Parameters field of the Program page, enter a left square bracket, a space, then a right square bracket, i.e., [ ] 3. If you want text to appear along with parameter prompting, insert the desired text between the square brackets. ═══ Settings notebook ═══ Parameters box of Settings notebook. ═══ 3.8. Finding a "covered" icon ═══ ═══ Covered icons window 1 ═══ The disadvantage of having many windows open on the desktop is that icons on the desktop can often get covered. To find an icon more easily: 1. Click the right mouse button on a clear space on the desktop. 2. Click on the arrow next to Open on the popup menu. 3. Choose Tree or Details View (Icon View can only be selected if the Desktop's object open behavior has been set to Create New Window); this will open up a new view of your desktop from which you can find the icon you want. ═══ Desktop Popup Menu ═══ Desktop's popup menu with Tree View highlighted. ═══ 3.9. Changing icon text color ═══ ═══ Color Palette ═══ The color of the icon text on your desktop can be changed as follows: 1. Open the Color Palette. 2. Hold the Ctrl key. 3. Use the right mouse button to drag the desired color to the desktop. Related subject(s): ■ Changing color of shadow icon text ═══ Color Palette ═══ Color Palette with color being dragged with mouse. ═══ 3.10. Recovering after an accidental Arrange ═══ To regain your desktop's icon positions after an accidental Arrange, use a third-party utility which can kill processes to kill the second instance of PMSHELL. The Workplace Shell will restart with your old icon positions. Related subject(s): ■ Saving desktop without shutting down ═══ 3.11. Creating an onscreen "app bar" ═══ ═══ App bar window 1 ═══ You can create something that acts a little like an "app bar": 1. Create a new folder. 2. Size the folder so that it has the shape and size that you like, then position it where you like. 3. Set the folder's view to either Flowed or Non-flowed. 4. Drag shadows of your most-used applications to the folder. 5. Drag a shadow of your "app bar" folder to your Startup folder. 6. You now have a folder of your most-used apps that will open at boot. You can further customize the "app bar" with a utility that will cause the folder to "float" on top of other windows so that it will be more accessible. ═══ App Bar ═══ Example of an App Bar. ═══ 3.12. Creating a "trash can" ═══ You can create a trash can-like icon on your desktop: 1. Open the Templates folder and make a copy of the Folder template. 2. You should now have a template called Folder:1; rename it to Trash, or whatever you like. 3. Attach you favorite trash can icon to your Trash template. 4. To create a trash can, use your right mouse button to drag a Trash folder from your Trash template onto your desktop. 5. Drag objects to the Trash as you see fit. 6. When you want to empty the Trash can, simply delete the folder, then replace it with a new Trash can by pulling one off of your Trash template. 7. The advantage of using the Trash can over the shredder is that you can open your Trash can and observe the contents, and remove what you don't want deleted. ═══ 3.13. Selecting objects without mouse ═══ You can select objects in folders or the Deskop without a mouse. Simply type the first letter of the object, and the object will be highlighted. Hit Enter to open the object. If more than one object begins with the same letter, subsequent typing of the same letter will jump between each object that begins with that letter. Related subject(s): ■ Selecting listbox entries without a mouse ═══ 3.14. Hiding a folder ═══ You can hide folder icons on the desktop so that others can't see them: 1. Open the Settings notebook of the folder which you wish to hide. 2. Click on the File tab, then click on the right arrow in the lower right corner to turn to the second page of the File tab. 3. Place a check mark next to Hidden under the Flags section. The folder should now be hidden. To view the folder's icon once again: 1. Open the Settings notebook for the Desktop. 2. Click on the Include tab. 3. Click on the right arrow in the lower right corner to turn to the second page of the Include tab. 4. Click on Change. A new dialog box will appear. 5. In the dialog box, choose the following settings: a) Property to be considered = Flags b) Comparison type = Not equal c) Comparison value = H 6. Click on Change. 7. Close Settings notebook. The icon should now be visible. ═══ 3.15. Creating a system file editor object ═══ You can create an object which, when opened, will open your system setup files for editing, through the aid of a Work Area folder: 1. Open the Settings notebook for the System Editor. 2. Click on the Association tab. 3. If Plain Text does not appear in the Current Types box, use the Add button to add it from the Available Types box. Close the Settings notebook. 4. Create a new folder. 5. Open the Settings notebook for the new folder. 6. Click on the File tab. 7. Place a check in the box next to Work Area. Close the Settings notebook. 8. Open the Drives object, then open the drive(s) with the CONFIG.SYS, WIN.INI, and SYSTEM.INI files. 9. Open the Settings notebook for the CONFIG.SYS file. 10. Click on Association. 11. If Plain Text does not appear in the Current Types box, use the Add button to add it from the Available Types box. Close the Settings notebook. Repeat for the Settings notebook for the WIN.INI and SYSTEM.INI files. 12. Drag shadows of the CONFIG.SYS, WIN.INI, and SYSTEM.INI files into the new folder. 13. Open the new folder if not already open. 14. Use the right mouse button on the CONFIG.SYS shadow object to popup the menu. Click on the arrow next to Open, choose System Editor. Your CONFIG.SYS should be loaded into the System Editor. Repeat for WIN.INI and SYSTEM.INI. 15. Leaving the three System Editor windows open, close the new folder. 16. You should now have a folder object that will open up your system files automatically when the folder is opened. ═══ 3.16. Retrieving a "changed" icon ═══ In OS/2 2.1, making changes to an object's settings often causes the object's icon to revert to its default icon. To retrieve your customized icon, this usually works: 1. Open the object's Settings notebook. 2. Choose the General tab. 3. Click on the Undo button. Related subject(s): ■ Managing your icons ═══ 3.17. Associating data files with programs ═══ ═══ Associate files ═══ Want to be able to double click on a data file object and have it open in its appropriate application? Try setting up associations in your applications: 1. Open the Settings notebook for the application. 2. Choose the Association tab. 3. Under Available Types, see if you can find the file type appropriate for your application. If so, highlight the file type, and press the Add button to the right of the box. 4. If the file type you need doesn't exist under Available Types, and the data files you wish to have associated have a common file extension or name, enter the common part of the filename (with appropriate wildcards) in the New Name box. Click on the Add button to the right of the box. 5. If neither of the above two situations applies, open up the Settings notebook for each data file you wish to associate, and set up the association there. Note that this does not work for all programs. ═══ Associations ═══ Settings notebook displaying Describe association. ═══ 3.18. Creating new printer objects ═══ To create a new printer object: 1. Open the Templates folder. 2. Drag a new printer object out from the Printer template with the right mouse button. 3. Customize the settings for your printer. ═══ 3.19. Creating your own templates ═══ You can create your own templates for customized uses. For example, you can create a template of a word processor file with boilerplate text for business letters. The next time you want to write a new business letter, just drag a copy off of your customized template, and the file, complete with your pre-defined settings, will be ready to edit. To create a customized template: 1. Customize your data file (such as a wordprocessor file) to the way you want it. Save the file. 2. Open the Drives object and find the file you just created. 3. Make a copy of the file object; you can either use Copy from the object's pop-up menu, or hold down the Ctrl key while dragging off a copy with your right mouse button. 4. Open the Settings notebook for the copy you just made. 5. Choose the General tab. 6. Place a check mark next to Template. Close the notebook. 7. When you want to use the new template, just use your right mouse button and drag a copy off of the template. ═══ 3.20. Replacing your Shredder if deleted ═══ Did you somehow manage to shred your Shredder? If so, SHREDDER.CMD can replace it. CAUTION: This REXX script does not check to see if you already have a Shredder present, and will replace one if it exists. Related subject(s): ■ Finding settings for original objects ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 3.21. Deleting "undeletable" objects ═══ If you find you have an undeletable object, this trick sometimes (but not always) works. 1. Insert a floppy disk in a floppy drive. 2. Open the Drives object. 3. Drag the undeletable object to the floppy drive object. Make sure that you are moving the object (you can ensure this by holding the Shift key while dragging). 4. Format the floppy disk. ═══ 3.22. Managing your icons ═══ ═══ Change icon ═══ contributed by George Orvis To manage your icons more easily: 1. Place your icons (*.ICO) into a subdirectory (or several subdirectories, if you have a large number of icons). 2. Create an object of that directory: a) Open the Drive object of the drive in which the icon subdirectory is located. b) Drag a shadow of the icon subdirectory into the desired location. 3. Set view of the folder to Icon View. 4. You now have a handy folder full of icons. If you double click on an icon, it starts the icon editor. 5. To change an object's icon (OS/2 2.1): a) Open the Settings notebook of the object. b) Choose the General tab. c) Drag an icon out of your icon folder with the right mouse button, and drop it onto the icon on the General page of the Settings notebook. Related subject(s): ■ Retrieving a "changed" icon ═══ Icon directory ═══ Directory of icon files ═══ Creating object ═══ Creating an icon directory object. ═══ Setting Icon view ═══ Setting icon directory folder to Icon view by default. ═══ Icon folder ═══ Folder full of icons. ═══ Changing an icon ═══ Changing an object's icon by dragging and dropping (OS/2 2.1). ═══ 3.23. Finding the built-in icons ═══ contributed by Xavier Caballe The REXX script ICONRES.CMD will find a number of built-in icons and place them into a folder on your desktop. Other REXX scripts: ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SLEEP.CMD ■ SHREDDER.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ═══ 4. Presentation Manager ═══ This section covers tips and tricks which affect Presentation Manager. Topics in this section: ■ Making fonts extremely small ■ Starting PM programs minimized ■ Changing the default PM system font ■ Moving a window in the background ■ Closing several windows at once ■ Using keyboard shortcuts in PM ■ Navigating in notebooks without a mouse ■ Changing the default view of a folder ■ Speeding up opening folders ■ Manipulating objects through the Window List ■ Selecting listbox entries without a mouse ■ Making "no-shows" re-appear ═══ 4.1. Making fonts extremely small ═══ ═══ Small fonts split window 1 ═══ You can make most Presentation Manager fonts as small as you like: 1. Open the Font Palette. 2. Double click on one of the fonts. A new dialog box will open. 3. Under "Size," highlight the font size shown in the box. 4. Type in a new font size that is non-zero (decimal values work); you should notice a corresponding change in the size of the font in the Sample box. Note that this trick does not work for System Proportional, System Monospaced, or System VIO fonts. Related subject(s): ■ Changing the default PM system font ═══ Font Palette ═══ Font Palette dialog box with point size highlighted. ═══ 4.2. Starting PM programs minimized ═══ from Tim Sipples' FAQ In order to start Presentation Manager programs minimized 1. Open the Settings notebook for the object. 2. On the Program page, change the name of the program so that it is misspelled. 3. Go to the Session page and click on Start Minimized. 4. Go back to the Program page, and correct the spelling of the program name. 5. Close the Settings notebook. ═══ 4.3. Changing the default PM system font ═══ You can change the default system font with a REXX script, SETFONT.CMD. However, the font used in the Settings notebooks will not be affected. Note: system fonts are designated by font size and font name, separated only by a period. (e.g., 8pt Helv would be designated by "8.Helv") Note: only the "default" fonts will work, e.g., Helv (not Helvetica), Tms Rmn (not Times Roman), System Proportional, and System Monospaced. Related subject(s): ■ Making fonts extremely small ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 4.4. Moving a window in the background ═══ You can move a window in the background without bringing it to the front by holding the Ctrl key and dragging the window by its title bar with your mouse. ═══ 4.5. Closing several windows at once ═══ ═══ Closing windows split window 1 ═══ You can close all or several of your open windows using the following method: 1. Bring up the Window List with Ctrl-Esc or clicking both mouse buttons at once. 2. Highlight the windows you want to close with your mouse. 3. Press the Delete key on your keyboard, or click your right mouse button on one of the highlighted entries and choose Close from the popup menu. ═══ Closing windows split window 2 ═══ Window List with highlighted items and popup menu. ═══ 4.6. Using keyboard shortcuts in PM ═══ There are plenty of keyboard shortcuts in Presentation Manager. Here are just a few of the lesser-known ones: 1. Alt-Backspace = undo last action (note that this doesn't always work). 2. Ctrl-Del = erase to end of field (useful when you have to retype text in a field - press Home to get to the beginning of a field, then Ctrl-Del to erase the text in the field - no more endless backspacing). 3. Alt-F4 = close window. 4. Alt-F5 = restore window. 5. Alt-F6 = move between related windows, such as between an application and its Help Window. 6. Alt-F7 = move window with cursor keys. 7. Alt-F8 = resize window with cursor keys. 8. Alt-F9 = minimize/hide window. 9. Alt-F10 = maximize window. 10. F5 = refresh window. Related subject(s): ■ Navigating in notebooks without a mouse ═══ 4.7. Navigating in notebooks without a mouse ═══ To navigate around the notebooks (such as an object's Settings notebook) without a mouse (note that sometimes these keys don't always act consistently): 1. Down/Up Arrows = moves between notebook tabs when a tab is highlighted 2. Tab = moves dotted box highlight between selections 3. Spacebar = moves to next page if its notebook tab is highlighted 4. Alt-Down Arrow = move from notebook tab to page 5. Alt-Up Arrow = move from page to notebook tab 6. Alt-PageDown = move to next page 7. Alt-PageUp = move to previous page 8. Ctrl-Tab = move to next field on a page 9. Shift-Tab = move to previous field on a page Related subject(s): ■ Using keyboard shortcuts in PM ═══ 4.8. Changing the default view of a folder ═══ ═══ Default folder view ═══ 1. Open the Settings notebook for the folder you wish to change. 2. Choose the Menu tab. 3. Highlight ~Open in the box marked Available Menus. 4. Click on the Settings button to the right of the box. A new dialog box will open. 5. Under Default Action, click on the down arrow next to the box. Several choices will be revealed. Choose the one you wish. 6. Click on OK, and close the Settings notebook. ═══ Changing default view ═══ Dialog box with Default Action choice. ═══ 4.9. Speeding up opening folders ═══ contributed by David Haar Folders open faster when set to Flowed view: 1. Open the Settings notebook for the folder. 2. On page 1 of the View section, click on Flowed. You may also wish to have the folders sorted automatically: 1. Open the Settings notebook for the folder. 2. Choose the Sort tab. 3. In the pull down box under Default Sort Attribute, choose which type of sorting you like. 4. Place a check next to Maintain Sort Order. 5. Close the Settings notebook. ═══ 4.10. Enlarging the mouse cursor ═══ ═══ Enlarge cursor ═══ You can make the mouse cursor larger on systems with standard VGA with LARGE.CMD. The system must be rebooted for the change to take effect. Other REXX scripts: ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ Enlarging mouse cursor ═══ Difference in standard and large cursor sizes. ═══ 4.11. Manipulating objects through the Window List ═══ You can affect objects that are listed in the Window List: ■ Holding the Shift key and double-clicking on an object's name in the Window List will minimize the application. ■ Holding the Ctrl key and double-clicking on an object's name in the Window List will maximize the application. ■ Holding the Alt key and double-clicking on an object's name in the Window List will allow you to change the name of the object. ═══ 4.12. Selecting listbox entries without a mouse ═══ An easy way to select an entry in a Presentation Manager listbox is to type the first letter of the name of the entry. Subsequent presses of the same letter will cycle through all listbox entries which start with that letter. Related subject(s): ■ Selecting objects without mouse ═══ 4.13. Making "no-shows" re-appear ═══ ═══ No shows ═══ Sometimes you will swear that you've opened an application, but for some reason, you don't see it onscreen (the Sticky Pad and Settings notebooks are especially notorious). Try this, and see if it does the trick: 1. Use Ctrl-Esc or click both mouse buttons simultaneously on the desktop to open the Window List. 2. Click the right mouse button on the name of the offending application. This will pop up the object's menu. 3. Choose either Tile or Cascade from the menu. The application should appear. ═══ "No shows" ═══ Window List with Tile choice selected for Settings notebook. ═══ 5. Command Line ═══ This section covers tips and tricks which affect command line sessions. Topics in this section: ■ Pasting text without the final carriage return ■ Clearing the Delete subdirectory ■ Searching for file names ■ Maximizing windows when opening ■ Creating a scroll buffer ■ Using OS/2 without the Workplace Shell ■ Enhancing speed of text scrolling ■ Adding entries to your PATH ■ Permanently deleting a file when Undelete is active ■ Suppressing echo from *.CMD files ■ Getting more out of your command line ■ Checking drive status ■ Shutting down from a REXX script automatically ■ Using multiple arguments at the OS/2 command line ■ Using EPM as a customized command shell ■ Setting the startup directory for command line objects ■ Formatting a diskette with the detach command ■ Resizing a command line window permanently ■ Making the system "sleep" ■ Substituting REPLACE for the COPY command ■ "Touching" a file's date and time ■ Adding command sessions to the desktop's popup menu ■ Opening multiple command line sessions from the desktop menu ■ Creating a command line calculator ■ Starting a DOS session with maximum free memory ■ Using START to avoid the dreaded "clock" ■ Coloring OS/2 command line sessions ═══ 5.1. Pasting text without the final carriage return ═══ To paste text after a copy/mark operation without a final carriage return, hold down the Shift key while choosing Paste from the pull-down menu. ═══ 5.2. Clearing the Delete subdirectory ═══ In order to remove the files from the Delete subdirectory of a drive to regain some drive space, type the following at a command line: UNDELETE :\* /f /s /a where is the letter of the drive which contains the Delete subdirectory you wish to clear. Related subject(s): ■ Permanently deleting a file when Undelete is active ═══ 5.3. Searching for file names ═══ To search for a particular file name on a drive, type DIR :\ /S where is the letter of the drive you wish to search is the specification of the file you are searching; standard wild cards can be used. ═══ 5.4. Maximizing windows when opening ═══ ═══ Maximizing windows split window 1 ═══ To make all command line windows open maximized, hold the Shift key while clicking on the maximize button. In some cases, you additionally may have to hold the Shift key while using the mouse to resize the window to its fullest size by dragging the bottom right corner. Related subject(s): ■ Resizing a command line window permanently ═══ Maximizing windows ═══ Command window with mouse pointer on Maximize button. ═══ 5.5. Creating a scroll buffer ═══ from Tim Sipples' FAQ To create a small scroll-back buffer for your command line sessions, type MODE 80,102 Related subject(s): ■ Resizing a command line window permanently ═══ 5.6. Using OS/2 without the Workplace Shell ═══ To use OS/2 without loading the Workplace Shell, replace the following line in your CONFIG.SYS SET RUNWORKPLACE=:\OS2\PMSHELL.EXE with SET RUNWORKPLACE=:\OS2\CMD.EXE where is the letter of the drive on which OS/2 is located. Note that you can always invoke the Workplace Shell by typing PMSHELL at an OS/2 command line. It can consequently be removed by closing it from the Window List. Related subject(s): ■ Booting OS/2 in full-screen mode ═══ 5.7. Enhancing speed of text scrolling ═══ Tricks for speeding up text display. Related subject(s): ■ Changing font size ■ Changing Video_ROM_Emulation ═══ 5.7.1. Changing font size ═══ ═══ Changing font size window 1 ═══ Fonts which are 8 pixels wide generally display faster than those which are not 8 pixels wide. Choose Font Size from the pull-down menu, then choose a "x 8" type of font size. ═══ Font Size dialog ═══ Font Size dialog box with 14x8 font size highlighted. ═══ 5.7.2. Changing Video_ROM_Emulation ═══ ═══ VideoROM window 1 ═══ Text scrolling speed can also be enhanced using the Video_ROM_Emulation setting. 1. Select DOS Settings from either the pull-down menu of a DOS session, or from the Session page of the Settings notebook of a DOS session. 2. Highlight Video_ROM_Emulation. 3. Try the setting both on and off to find out if one setting results in better performance than the other. ═══ DOS Settings ═══ DOS Settings dialog with Video_ROM_Emulation highlighted. ═══ 5.8. Adding entries to your PATH ═══ You can add entries to your PATH "on the fly" by using: PATH %PATH%;:\ where is the drive on which the subdirectory you want to add is located is the path you want to add (This also works for DPATH) ═══ 5.9. Permanently deleting a file when Undelete is active ═══ If you have Undelete activated (via SET DELDIR in your CONFIG.SYS), but want to delete a file or files so they can't be undeleted, use: DEL /F where is the file specification of the file(s) you want to delete Related subject(s): ■ Clearing the Delete subdirectory ═══ 5.10. Suppressing echo from *.CMD files ═══ If you are using batch files (*.CMD) which do not have ECHO OFF statements, you can also suppress the echo by using the /Q switch: Example: BATCH.CMD /Q ═══ 5.11. Getting more out of your command line ═══ Supplement your command line usage by stacking commands with &&, &, ||, and (): contributed by Jack Tan 1. && executes the second program only if the former succeeds, e.g., RunMe.EXE && RunMeIfFormerSucceeds.EXE 2. || executes the second program if the former doesn't succeed, e.g., RunMe.EXE || RunMeIfTheFormerDidntSucceed.EXE 3. Combining && and || results in an if..then..else situation, e.g., If.EXE && Then.EXE || Else.EXE (Else.EXE doesn't run if and only if both If.EXE and Then.EXE run successfully) 4. & runs both the first and second programs, e.g., RunMe.EXE & AndMeToo.EXE 5. () executes the instructions within the parentheses, overriding the normal order of command precedence, e.g., DETACH (FORMAT a: /once /v:"hi" && XCOPY c:\x A: /S) & UNZIP myfile.zip (the commands in parentheses are operated on by DETACH, then UNZIP executes) ═══ 5.12. Checking drive status ═══ inspired by a code snippet by Dick Goran You can check the status of a drive (e.g., if a floppy is inserted into a floppy drive or not) with a REXX script, CHKDRIVE.CMD. The routines in CHKDRIVE.CMD can be incorporated into longer REXX scripts whenever the status of a drive needs to be ascertained. Other REXX scripts: ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ SHUTDOWN.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 5.13. Shutting down from a REXX script automatically ═══ by David Matocha You can shutdown your system with a countdown using SHUTDOWN.CMD combined with a scheduling utility and a automatic power-down of the system. Related subject(s): ■ Rebooting from the command line ■ OPEN.CMD ■ BITMAP.CMD ■ SETPTR.CMD ■ SETFONT.CMD ■ CHKDRIVE.CMD ■ SHREDDER.CMD ■ SLEEP.CMD ■ LARGE.CMD ■ EVAL.CMD ■ BIGDOS.CMD ■ ICONRES.CMD ═══ 5.14. Using multiple arguments at the OS/2 command line ═══ Unlike DOS, OS/2's command line allows you to use multiple arguments at the command line for the DEL and DIR commands. e.g., DEL DIR where , , and are different filenames (with any appropriate wildcards). ═══ 5.15. Using EPM as a customized command shell ═══ ═══ EPM shell ═══ contributed by Jack Tan Use the Enhanced Editor (EPM) command SHELL to produce a command line with the following attributes: ■ Uses any font recognized by EPM. ■ Window sizeable to nearly any size. ■ Dynamically resizeable window. ■ Can alter text/background colors. ■ Scroll buffer spans the entire session. Unfortunately, programs which take control of the screen (like screen-based editors) won't run. ═══ EPM command shell ═══ EPM command shell, using the Helvetica font. ═══ 5.16. Setting the startup directory for command line objects ═══ contributed by Jack Tan The 'Working Directory' entry in the settings notebook also applies to command lines, such as 'OS/2 Window' and 'DOS Full Screen.' In these cases, the working directory becomes the starting directory. ═══ 5.17. Formatting a diskette with the detach command ═══ You can format a diskette in the background from the command line or in a batch file without user intervention with the line: DETACH FORMAT : /ONCE /V: